<template>
  <view class="page">
    <Header :title="'我的'"></Header>
    <view class="main_container">
      <view class="main_content">
        <Breadcrumb :text="'我的-今日复习'"> </Breadcrumb>
        <view class="content">
          <view class="title"> 复习记录 </view>
          <view class="box">
            <view class="list">
              <view
                class="item"
                v-for="(item, index) in list"
                :key="index"
                @click="switchPage(`/pages/user/todayReviewList?dateTime=${item.dateTime}`)"
              >
                <view class="item_img">
                  <image
                    src="https://hengxiao-resource.oss-cn-hangzhou.aliyuncs.com/web/resources/images/hengxiao/user/book.png"
                    mode="scaleToFill"
                  />
                </view>
                <view class="item_text"> {{ item.name }} </view>
                <view class="item_icon">
                  <u-icon name="arrow-right" color="#fff" size="42"></u-icon>
                </view>
              </view>
            </view>
          </view>
        </view>
      </view>
    </view>
  </view>
</template>

<script>
import { getJrfxTime } from "@/api/sync";
export default {
  components: {},
  data() {
    return {
      list: [],
    };
  },
  onLoad() {
    this.getData();
  },
  methods: {
    getData() {
      getJrfxTime("1").then((res) => {
        this.list = res.data;
      });
    },
    switchPage(url) {
      uni.navigateTo({
        url: url,
      });
    },
  },
};
</script>

<style lang="scss" scoped>
@import "./todayReview.scss";
</style>
